%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
%% Package `VauCanSon-G'  version 0.4
%%
%% This is file `vaucanson-g.sty'.
%%
%% IMPORTANT NOTICE:
%%
%% Copyright (C) 2002-2008 Sylvain Lombardy and Jacques Sakarovitch
%%
%% This package may be distributed under the terms of the LaTeX Project
%% Public License, as described in lppl.txt in the base LaTeX distribution.
%% Either version 1.0 or, at your option, any later version.
%%
%% DESCRIPTION:
%%
%%   `vaucanson-g.sty' is the wrapper for the package `VauCanSon-G'
%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\ProvidesPackage{vaucanson-g}%
   [2008/10/27 package wrapper for VauCanSon-G  v. 0.4]
   \def\fileversion{0.4}
   \def\filedate{2008/10/27}
\DeclareOption{default}{} % default option
%\DeclareOption{slides}{\AtEndOfPackage{\input VCPref-slides.tex}}
%\DeclareOption{beamer}{\AtEndOfPackage{\input VCPref-beamer.tex}}
% next is preparation for a user defined style file
\DeclareOption{mystyle}{\AtEndOfPackage{\input VCPref-mystyle.tex}}
%%%% option for compatibility with 0.3 (thanks, Akim, for the option)
\DeclareOption{pstricks1-10}{} % explicit option is now unnecessary
\ProcessOptions
%%%%
\RequirePackage{ifthen}

%\RequirePackage[pst]{xcolor}


% compatibility with older version of xcolor
\input{VCColor-names.def}
%
\RequirePackage{pstricks}
% PSTricks 1.10 changed \scalebox.  Compatibility hack.
\@ifpackagelater{pstricks}{2005/08/20}%
   {\def\scalebox{\psscalebox}}{}%
\RequirePackage{pst-node}
%\RequirePackage{pst-plot}
%\RequirePackage{pst-coil}
%\RequirePackage{multido}
%\RequirePackage{pst-3d}
\RequirePackage{calc}
\input Vaucanson-G.tex
% PSTricks 1.10 changed the interface.  Compatibility hack.
\@ifpackagelater{pstricks}{2005/08/20}
   {%
    \def\VaucProjectionOnSecondComponent(#1,#2)(#3,#4){#2}%
    \def\VaucProjectionOnFourthComponent(#1,#2)(#3,#4){#4}%
    \newlength{\VaucMinHeight}%
    \newlength{\VaucMaxHeight}%
    \renewenvironment{VCPicture}[2][.5]%
      {\settoheight{\VertShiftH}{$\{$}%
       \settodepth{\VertShiftD}{$\{$}%
       \setlength{\VertShift}{.5\VertShiftD-.5\VertShiftH}%
       \pssetlength{\VaucMinHeight}{\VaucProjectionOnSecondComponent#2}%
       \pssetlength{\VaucMaxHeight}{\VaucProjectionOnFourthComponent#2}%
       \addtolength{\VaucMinHeight}{-\VaucMaxHeight}%
       \begin{pspicture}[shift=#1\VaucMinHeight]#2%
       \ifVCFrame \FrameStyle \psframe#2\fi%
       \ifVCGrid \FrameStyle\GridStyle \psgrid#2\fi}%
      {\RstState\RstEdge\end{pspicture}}%
   }%
   {}
\input VCPref-default.tex % Initialization with default values
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\endinput
